-
Notifications
You must be signed in to change notification settings - Fork 7.7k
drivers: ethernet: Add Intel® i226 Ethernet Controller Driver #88108
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
base: main
Are you sure you want to change the base?
drivers: ethernet: Add Intel® i226 Ethernet Controller Driver #88108
Conversation
Hello @Vijayakannan, and thank you very much for your first pull request to the Zephyr project! |
f78f26a
to
0e25402
Compare
On a first look:
|
Hi Fin Maaß, Thanks for spending time to review and recommendations.
I agree with your suggestions and work on it. Rationale on why earlier decided to use MAC for Link detection: I am open for your suggestion in case if you have other thoughts. - Thanks, Vijay |
Progress Update: |
288ebf7
to
03d2fc2
Compare
0f1a01e
to
7210410
Compare
Hi @maass-hamburg, All the review comments were addressed in this PR version 7. Please review and share feedback. Thanks, Vijay Changes since v6:
|
7210410
to
3bd0d2e
Compare
Hi @maass-hamburg, please review and approve this PR.? |
3bd0d2e
to
75fd2a6
Compare
75fd2a6
to
771b9cc
Compare
Hi @maass-hamburg, please review PR revision v8. Changes since PR version v7: |
771b9cc
to
5f500c7
Compare
Hi @maass-hamburg, please review PR revision v9. Changes since PR version v8:
|
5f500c7
to
e3e912d
Compare
Hi @maass-hamburg, could you please share your feedback on this updated PR version? |
struct eth_intel_igc_mac_tx *tx; | ||
struct eth_intel_igc_mac_rx *rx; |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
struct eth_intel_igc_mac_tx *tx; | |
struct eth_intel_igc_mac_rx *rx; | |
struct eth_intel_igc_mac_tx tx; | |
struct eth_intel_igc_mac_rx rx; |
I meant this, when I said to put it in it.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I meant this, when I said to put it in it.
Got it. This change requires updating the overall code. I can make the necessary modifications and update this PR.
Please let me know if there are any other review comments to address in the next version. I need to expedite this PR due to the long pending pull request.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I meant this, when I said to put it in it.
Good catch and suggestion. All the required changes are already resolved in the updated version.
e3e912d
to
45305c5
Compare
The Ethernet device model consists of multiple subsystem components, such as MDIO, PHY, MAC and PTP_CLOCK. These components are mapped into a single PCIe BAR location with same base address. This platform driver retrieves the MMIO mapping details and provides a framework to share it with all the child subsystem components. This approach avoid the duplicate remapping, ensures efficient re-use of MMIO mappings across related devices. Example device tree structure for first ethernet instance: parent0: parent0 { compatible = "intel,eth-plat"; interrupt-parent = <&intc>; vendor-id = <0x8086>; device-id = <0xXXXX>; igc0: igc0 { compatible = "intel,igc-mac"; /* * MAC specific properties. */ status = "okay"; }; mdio0: mdio0 { compatible = "intel,igc-mdio"; #address-cells = <1>; #size-cells = <0>; ethphy0: ethernet-phy@0 { compatible = "ethernet-phy"; /* * PHY specific properties. */ reg = <0x0>; }; }; }; This framework is modular and re-usable for other PCIe based Ethernet devices. It can also be extended to support additional platform specific information shared across child nodes. Signed-off-by: Vijayakannan Ayyathurai <vijayakannan.ayyathurai@intel.com>
Intel i226 MAC supports MDIO C22 and MDIO C45. Standard PHY registers are accessible through MDIO C22, whereas PMAPMD and PCS are accssible through MDIO C45. Signed-off-by: Vijayakannan Ayyathurai <vijayakannan.ayyathurai@intel.com>
The Intel i226 Ethernet Controller is a PCIe Gen 2 one-lane modular endpoint device that integrates a GbE Media Access Control (MAC) and Physical Layer (PHY) port. This driver provides support for MAC and DMA-specific initialization and runtime TX/RX operations. Key features: - MSI-X interrupts for TX/RX DMA channels. - Multiple TX/RX DMA channel support with exclusive bottom-half. - Implements a circular descriptor ring architechture with producer-consumer semantics for high performance pkt processing. - Full duplex support for 10/100/1000 Mbps. - Half duplex support for 10/100 Mbps. - Auto-negotiation for 10/100/1000 Mbps. - MTU customization for flexible packet sizes. - MAC address filtering based on: - Random MAC generation. - Local-mac-address mentioned in device tree. - EEPROM pre-programmed mac address. - Setting mac address via net shell. - Support for multiple Ethernet interface instances. Signed-off-by: Vijayakannan Ayyathurai <vijayakannan.ayyathurai@intel.com> Signed-off-by: Ling Pei Lee <pei.lee.ling@intel.com>
Foxville LM (0x125B) i226 variant and Intel Alder Lake platform was used for developing and stabilizing the i226 Ethernet device driver. However, users can reuse the provided device tree models as a reference when enabling the support for other i226 variants and platforms. This device-tree model include essential configurations for the i226 Ethernet controller, such as PCIe settings, interrupt mappings, Phy MDIO, and DMA descriptor configurations. Signed-off-by: Vijayakannan Ayyathurai <vijayakannan.ayyathurai@intel.com>
The Zperf sample application was chosen to demonstrate basic network functionality and high-performance use cases. This application serves as a reference for users who wish to enable other network sample applications. In addition to the essential configurations for the Intel i226 Ethernet controller, stack-specific configurations were added to ensure stability under heavy network loads. These configurations include adjustments to buffer sizes, interrupt handling, and DMA descriptor management. Signed-off-by: Vijayakannan Ayyathurai <vijayakannan.ayyathurai@intel.com>
45305c5
to
884a682
Compare
|
The Intel i226 Ethernet Controller is a PCIe Gen 2 one-lane modular endpoint device that integrates a fully featured GbE Media Access Control (MAC) and Physical Layer (PHY) port. This PR introduces a complete driver bundle to enable Intel i226 Ethernet Controller.
Components:
Features Supported:
Other Notes:
Validation Coverage:
This driver bundle has been tested on Intel Alder Lake platforms with the Intel i226 LM variant Ethernet Controller(0x125B). The ZPERF network sample application was used to validate basic functionality, performance, and stability.
Test List: